// pages/map/map.js
Page({

    /**
     * 页面的初始数据
     */
    data: {
        latitude: 23.255831,
        longitude: 113.906029,
        markers: [{
            iconPath: '../../images/navi.png',
            id: 1,
            latitude: 23.256331683789917,
            longitude: 113.9057913643341,
            width: 30,
            height: 30
        }]
    },


    markertap() {
        wx.openLocation({
          latitude: this.data.latitude,
          longitude: this.data.longitude,
          name: '广州珠江职业技术学院',
          addrss: '莲塘岗村'
        })
    },

    btnTap() {
        wx.getLocation({
          type: 'gcj02',
          success(res) {
              console.log(res);
              wx.openLocation({
                latitude: res.latitude,
                longitude: res.longitude,
              })
          }
        })
    }
})